import './interfaces';
import del from './atom/db/del';

async function atom(msg: Message, headers: IHeaders) {
	const systemid = '@systemid';
	const { exec, prepare } = del(headers.actionid, headers.sessionid, headers.spaceid, systemid);
	prepare('@tname1', [{ _id: '@_id' }, { _id: '@_id' }]);
	prepare('@tname2', [{ _id: '@_id' }]);
	const ret = await exec()
	if (ret.code === 1) {
		return 'success';
	} else {
		return 'fail';
	}
}
